-- *****************************************************************
-- CISCO-MODULE-AUTO-SHUTDOWN-MIB
--   
-- December 2003, Seth Wang
--   
-- Copyright (c) 2003, 2008 by cisco Systems Inc.
-- All rights reserved.
-- *****************************************************************

CISCO-MODULE-AUTO-SHUTDOWN-MIB DEFINITIONS ::= BEGIN

IMPORTS
    MODULE-IDENTITY,
    OBJECT-TYPE,
    NOTIFICATION-TYPE,
    Gauge32,
    Unsigned32
        FROM SNMPv2-SMI
    MODULE-COMPLIANCE,
    OBJECT-GROUP,
    NOTIFICATION-GROUP
        FROM SNMPv2-CONF
    TruthValue,
    DateAndTime,
    TEXTUAL-CONVENTION
        FROM SNMPv2-TC
    SnmpAdminString
        FROM SNMP-FRAMEWORK-MIB
    entPhysicalIndex,
    entPhysicalName,
    entPhysicalModelName
        FROM ENTITY-MIB
    ciscoMgmt
        FROM CISCO-SMI;


ciscoModuleAutoShutdownMIB MODULE-IDENTITY
    LAST-UPDATED    "200803120000Z"
    ORGANIZATION    "Cisco Systems, Inc."
    CONTACT-INFO
            "Cisco Systems
            Customer Service

            Postal: 170 W Tasman Drive
            San Jose, CA 95134
            USA

            Tel: +1 800 553-NETS

            E-mail: cs-lan-switch-snmp@cisco.com"
    DESCRIPTION
        "The CISCO-MODULE-AUTO-SHUTDOWN-MIB is used to configure
        the module automatic shutdown feature. Modules will be
        reset by the system when they become faulty. The module
        auto shutdown feature will shutdown such faulty modules
        when the resets occur too often. Once the modules are
        shutdown by this feature, they will stay shutdown until
        the administrator manually brings them back up. This will
        prevent the system from constantly resetting the faulty
        modules.

        This MIB module also covers the system initiated action 
        occuring on a module."
    REVISION        "200803120000Z"
    DESCRIPTION
        "Added the TC CiscoModuleAutoShutSysAction and the groups
        cmasModuleSysActionGroup and cmasNotificationsGroup2."
    REVISION        "200312290000Z"
    DESCRIPTION
        "Initial revision of this MIB module."
    ::= { ciscoMgmt 386 }


cmasMIBNotifs  OBJECT IDENTIFIER
    ::= { ciscoModuleAutoShutdownMIB 0 }

cmasMIBObjects  OBJECT IDENTIFIER
    ::= { ciscoModuleAutoShutdownMIB 1 }

cmasMIBConformance  OBJECT IDENTIFIER
    ::= { ciscoModuleAutoShutdownMIB 2 }

cmasGlobal  OBJECT IDENTIFIER
    ::= { cmasMIBObjects 1 }

cmasNotifObjects  OBJECT IDENTIFIER
    ::= { cmasMIBObjects 2 }

cmasModule  OBJECT IDENTIFIER
    ::= { cmasMIBObjects 3 }

cmasModuleSysActionObjects  OBJECT IDENTIFIER
    ::= { cmasMIBObjects 4 }


CiscoModuleAutoShutSysAction ::= TEXTUAL-CONVENTION
    STATUS          current
    DESCRIPTION
        "The type of system initiated action.
        Valid values are:

        other(1):       none of the below.

        reset(2):       reset the module.

        powerCycle(3):  power cycle the module.

        powerDown(4):   power down the module."
    SYNTAX          INTEGER  {
                        other(1),
                        reset(2),
                        powerCycle(3),
                        powerDown(4)
                    }

cmasFrequency OBJECT-TYPE
    SYNTAX          Unsigned32
    MAX-ACCESS      read-write
    STATUS          current
    DESCRIPTION
        "This indicates the threshold of the number of times
        the system can reset a faulty module, within the period
        specified by 'cmasPeriod'. Once the number of these system
        initiated resets exceeds this threshold, the module auto
        shutdown feature will shut down the module." 
    ::= { cmasGlobal 1 }

cmasPeriod OBJECT-TYPE
    SYNTAX          Unsigned32
    UNITS           "minutes"
    MAX-ACCESS      read-write
    STATUS          current
    DESCRIPTION
        "This indicates the period of time over which the number of
        system initiated module resets is monitored. In order for
        the module to be automatically shutdown, the number of times
        the system must reset the module has to exceed cmasFreqency
        times, in a span of cmasPeriod." 
    ::= { cmasGlobal 2 }

cmasMIBEnableNotification OBJECT-TYPE
    SYNTAX          TruthValue
    MAX-ACCESS      read-write
    STATUS          current
    DESCRIPTION
        "This object indicates whether the system produces the
        cmasModuleAutoShutdown notification."
    DEFVAL          { false } 
    ::= { cmasNotifObjects 1 }

cmasModuleSysActionNotifEnable OBJECT-TYPE
    SYNTAX          TruthValue
    MAX-ACCESS      read-write
    STATUS          current
    DESCRIPTION
        "This object indicates whether the system produces the
        cmasModuleSysActionNotif notification."
    DEFVAL          { false } 
    ::= { cmasNotifObjects 2 }

cmasModuleTable OBJECT-TYPE
    SYNTAX          SEQUENCE OF CmasModuleEntry 
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "This table contains information regarding the module
        auto shutdown feature."
    ::= { cmasModule 1 }

cmasModuleEntry OBJECT-TYPE
    SYNTAX          CmasModuleEntry
    MAX-ACCESS      not-accessible
    STATUS          current
    DESCRIPTION
        "This entry contains information about the module auto
        shutdown feature. Each entry represents whether the
        feature is enabled, the number of resets, the last
        reset reason and the last reset time. Each entry is
        applicable for the modules capable of this feature and
        are identified by 'entPhysicalIndex' with entPhysicalClass
        value 'module'."
    INDEX           { entPhysicalIndex } 
    ::= { cmasModuleTable 1 }

CmasModuleEntry ::= SEQUENCE {
        cmasModuleEnable          TruthValue,
        cmasModuleNumResets       Gauge32,
        cmasModuleLastResetReason SnmpAdminString,
        cmasModuleLastResetTime   DateAndTime
}

cmasModuleEnable OBJECT-TYPE
    SYNTAX          TruthValue
    MAX-ACCESS      read-write
    STATUS          current
    DESCRIPTION
        "This object enables or disables the auto shutdown feature
        on a module.

        When the object is true(1), auto shutdown is enabled for
        that module. The feature will start monitoring system
        initiated module resets, and initiate a shutdown operation
        on the module if the number of resets, cmasModuleNumResets,
        exceeds the cmasFrequency within the previous cmasPeriod of
        time.

        When the object is false(2), auto shutdown is disabled for
        that module." 
    ::= { cmasModuleEntry 1 }

cmasModuleNumResets OBJECT-TYPE
    SYNTAX          Gauge32
    MAX-ACCESS      read-only
    STATUS          current
    DESCRIPTION
        "This indicates the number of system initiated module resets
        that have occurred. This does not include user initiated
        module resets." 
    ::= { cmasModuleEntry 2 }

cmasModuleLastResetReason OBJECT-TYPE
    SYNTAX          SnmpAdminString
    MAX-ACCESS      read-only
    STATUS          current
    DESCRIPTION
        "This object identifies the reason for the last module
        reset initiated by the system. This object will contain
        a zero-length string if no such resets have occurred." 
    ::= { cmasModuleEntry 3 }

cmasModuleLastResetTime OBJECT-TYPE
    SYNTAX          DateAndTime
    MAX-ACCESS      read-only
    STATUS          current
    DESCRIPTION
        "This object corresponds to the date and time when the last
        system initiated module reset occurred. This object will
        contain 0-1-1,00:00:00:0 if no system initiated resets have
        occurred." 
    ::= { cmasModuleEntry 4 }
 


cmasModuleSysAction OBJECT-TYPE
    SYNTAX          CiscoModuleAutoShutSysAction
    MAX-ACCESS      accessible-for-notify
    STATUS          current
    DESCRIPTION
        "This object identifies the system initiated action which
        is applied to a module." 
    ::= { cmasModuleSysActionObjects 1 }

cmasModuleSysActionReason OBJECT-TYPE
    SYNTAX          SnmpAdminString
    MAX-ACCESS      accessible-for-notify
    STATUS          current
    DESCRIPTION
        "This object identifies the reason of system initiated
        action which is applied to a module." 
    ::= { cmasModuleSysActionObjects 2 }

-- Notifications

cmasModuleAutoShutdown NOTIFICATION-TYPE
    OBJECTS         {
                        entPhysicalName,
                        entPhysicalModelName,
                        cmasModuleNumResets,
                        cmasModuleLastResetReason
                    }
    STATUS          current
    DESCRIPTION
        "This notification is generated when the module auto
        shutdown feature shuts down a module."
   ::= { cmasMIBNotifs 1 }

cmasModuleSysActionNotif NOTIFICATION-TYPE
    OBJECTS         {
                        entPhysicalName,
                        entPhysicalModelName,
                        cmasModuleSysAction,
                        cmasModuleSysActionReason
                    }
    STATUS          current
    DESCRIPTION
        "This notification is generated when a system initiated
        action occurs on a module."
   ::= { cmasMIBNotifs 2 }
-- Conformance

cmasMIBCompliances  OBJECT IDENTIFIER
    ::= { cmasMIBConformance 1 }

cmasMIBGroups  OBJECT IDENTIFIER
    ::= { cmasMIBConformance 2 }


cmasMIBCompliance MODULE-COMPLIANCE
    STATUS          deprecated
    DESCRIPTION
        "The compliance statement for the
        CISCO-MODULE-AUTO-SHUTDOWN-MIB"
    MODULE          -- this module
    MANDATORY-GROUPS {
                        cmasModuleGroup,
                        cmasNotificationEnableGroup,
                        cmasNotificationsGroup
                    }
    ::= { cmasMIBCompliances 1 }

cmasMIBCompliance2 MODULE-COMPLIANCE
    STATUS          current
    DESCRIPTION
        "The compliance statement for the
        CISCO-MODULE-AUTO-SHUTDOWN-MIB"
    MODULE          -- this module
    MANDATORY-GROUPS {
                        cmasModuleGroup,
                        cmasNotificationEnableGroup,
                        cmasNotificationsGroup
                    }

    GROUP           cmasModuleSysActionGroup
    DESCRIPTION
        "This group is mandatory for devices which support
        system initiated module action feature."

    GROUP           cmasNotificationsGroup2
    DESCRIPTION
        "This group is mandatory for devices which support
        system initiated module action feature."
    ::= { cmasMIBCompliances 2 }

-- Units of Conformance

cmasModuleGroup OBJECT-GROUP
    OBJECTS         {
                        cmasFrequency,
                        cmasPeriod,
                        cmasModuleEnable,
                        cmasModuleNumResets,
                        cmasModuleLastResetReason,
                        cmasModuleLastResetTime
                    }
    STATUS          current
    DESCRIPTION
        "A collection of objects which are used to configure as
        well as show information regarding the module auto
        shutdown feature."
    ::= { cmasMIBGroups 1 }

cmasNotificationEnableGroup OBJECT-GROUP
    OBJECTS         { cmasMIBEnableNotification }
    STATUS          current
    DESCRIPTION
        "A collection of objects which are used to enable
        notifications."
    ::= { cmasMIBGroups 2 }

cmasNotificationsGroup NOTIFICATION-GROUP
   NOTIFICATIONS    { cmasModuleAutoShutdown }
    STATUS          current
    DESCRIPTION
        "A collection of notifications for the module auto
        shutdown feature."
    ::= { cmasMIBGroups 3 }

cmasModuleSysActionGroup OBJECT-GROUP
    OBJECTS         {
                        cmasModuleSysActionNotifEnable,
                        cmasModuleSysAction,
                        cmasModuleSysActionReason
                    }
    STATUS          current
    DESCRIPTION
        "A collection of objects which are related with
        the notification cmasModuleSysActionNotif. They are
        either used to enable and disable this notification
        or included in this notification PDU."
    ::= { cmasMIBGroups 4 }

cmasNotificationsGroup2 NOTIFICATION-GROUP
   NOTIFICATIONS    { cmasModuleSysActionNotif }
    STATUS          current
    DESCRIPTION
        "A collection of notifications for the system initiated
        module action feature."
    ::= { cmasMIBGroups 5 }

END